package com.example.schedule.Service.Impl;

import com.example.schedule.Mapper.LoginMapper;
import com.example.schedule.Service.LoginService;
import com.example.schedule.domain.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class LoginServiceImpl implements LoginService {
    @Autowired
    private LoginMapper loginMapper;

    @Override
    public User login(String username, String password) {
        User user = loginMapper.login(username, password);
        return user;
    }

    @Override
    public void add(User user) {
        loginMapper.add(user);
    }
}
